package com.ll.blog.contant;


import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

import java.io.File;
@Component
public class Constant {
    public static String FILE_UPLOAD_DIR;
    @Value("${file.upload.ip}")
    public void setFileUploadId(String fileUploadId) {
        FILE_UPLOAD_ID = fileUploadId;
    }

    public static String FILE_UPLOAD_ID;
    //    public static final String FILE_UPLOAD_DIR = System.getProperty("user.dir") + "/src/main/resources/image/";
    public  static String SALT = "jskdhjsh";
    public static String JWT_KEY = "jwtbyone";
    public static String user_id ="id";
    public static String role = "role";
    public static Integer ROLE_USER = 0;
    public static Integer ROLE_ADMIN =1;
    @Value("${file.upload.dir}")
    public void setFileUploadDir(String fileUploadDir) {
        FILE_UPLOAD_DIR = fileUploadDir;
    }


}
